package com.wcity.manage.service.community.permit.impl;

import com.wcity.manage.common.vo.community.permit.PermitVo;
import com.wcity.manage.dao.mapper.community.permit.PermitMapper;
import com.wcity.manage.dao.model.community.permit.Permit;
import com.wcity.manage.service.community.permit.PermitService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

/**
 * 证件类型
 * Created by hgg on 2016/12/17.
 */
@Service
public class PermitServiceImpl implements PermitService{

    @Autowired
    private PermitMapper permitMapper;

    /**
     * 证件类型列表
     * @param queryMap
     * @return
     */
    @Override
    public List<PermitVo> permitPageList( Map<String, Object> queryMap ) {

        return permitMapper.permitPageList( queryMap );
    }

    /**
     * 删除证件类型
     * @param deleteMap
     * @return
     */
    @Override
    public Integer deletePermit( Map<String, Object> deleteMap ) {

        return permitMapper.deletePermit( deleteMap );
    }

    /**
     * 新增证件类型
     * @param permit
     * @return
     */
    @Override
    public Integer saveAddPermit( Permit permit ) {

        return permitMapper.saveAddPermit( permit );
    }

    /**
     * 更新证件类型
     * @param permit
     * @return
     */
    @Override
    public Integer saveUpdatePermit( Permit permit ) {

        return permitMapper.saveUpdatePermit( permit );
    }

    /**
     * 证件类型详情
     * @param detailMap
     * @return
     */
    @Override
    public PermitVo permitDetail( Map<String, Object> detailMap ) {

        return permitMapper.permitDetail( detailMap );
    }

    /**
     * 证件类型总数量
     * @param queryMap
     * @return
     */
    @Override
    public Integer totalPermit( Map<String,Object> queryMap ){

        return permitMapper.totalPermit(queryMap);
    }

    /**
     * 证件类型列表非分页
     * @param queryMap
     * @return
     */
    @Override
    public List<PermitVo> permitList( Map<String, Object> queryMap ) {

        return permitMapper.permitList( queryMap );
    }
}
